/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package org.mldn.demo;

/**
 *
 * @author Administrator
 */
public class GenericsPoint {
    public static void main(String[] args){
        Point<Integer> p = new Point<Integer>();
        p.setX(10);
        p.setY(52);
        int x=p.getX();
        int y=p.getY();
        System.out.println("integer,x="+x);
        System.out.println("integer,y="+y);
       
    }
}

class Point<T> {
    private T x;
    private T y;

    public T getX() {
        return x;
    }

    public void setX(T x) {
        this.x = x;
    }

    public T getY() {
        return y;
    }

    public void setY(T y) {
        this.y = y;
    }
    
}
